from .. import db
from datetime import datetime


class AppVip(db.Model):
    __tablename__ = 'app_vip'
    id = db.Column(db.Integer, primary_key=True)
    app_vip_id = db.Column(db.String(50))
    country_code = db.Column(db.String(10))
    phone_num = db.Column(db.String(20))
    app_type = db.Column(db.String(10))
    url_addr = db.Column(db.String(50))
    url_create_at = db.Column(db.DateTime)
    vip_type = db.Column(db.String(10))
    vip_cycle = db.Column(db.String(10))
    vip_share_num = db.Column(db.Integer, default=0)
    vip_share_remain = db.Column(db.Integer, default=0)
    vip_exchange_code = db.Column(db.String(50))
    create_at = db.Column(db.DateTime, default=datetime.now())
